package cn.exrick.service.impl;

import cn.exrick.mapper.TbMemberVipRuleMapper;
import cn.exrick.pojo.TbMemberVipRule;
import cn.exrick.service.MemberVipRuleService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author wm
 * @date 2018/12/24
 */
@Service
public class MemberVipRuleServiceImpl implements MemberVipRuleService {

    @Autowired
    private TbMemberVipRuleMapper tbMemberVipRuleMapper;

    @Override
    public List<TbMemberVipRule> queryAll() {
        return tbMemberVipRuleMapper.selectByExample(null);
    }

    @Override
    public TbMemberVipRule queryById(Integer id) {
        return tbMemberVipRuleMapper.selectByPrimaryKey(id);
    }

    @Override
    public void update(TbMemberVipRule tbMemberVipRule) {
        tbMemberVipRuleMapper.updateByPrimaryKeySelective(tbMemberVipRule);
    }

}
